﻿using AutoMapper;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using WorkflowCore2210A.Application.Dto.Input;
using WorkflowCore2210A.Application.Dto.Output;
using WorkflowCore2210A.Domain.Model;

namespace WorkflowCore2210A.Application
{
    public class WorkflowProfile:Profile
    {
        public WorkflowProfile()
        {
            CreateMap<WorkflowDefinitionInput, WorkflowDefinitionModel>()
                .ForMember(p => p.Steps, opt => opt.Ignore());


            CreateMap<AddAuditInput, AuditModel>();

            CreateMap<AddWorkflowInstanceInput, WorkflowInstanceModel>();


            CreateMap<WorkflowDefinitionModel, WorkflowDefinitionOutput>();

            CreateMap<WorkflowInstanceModel, WorkflowInstanceOutput>();

            //CreateMap<UserModel, UserOutput>();

            CreateMap<AuditModel, AuditOutput>();
        }
    }
}
